home *** CD-ROM | disk | FTP | other *** search
/ User's Choice Windows CD / User's Choice Windows CD (CMS Software)(1993).iso / windows4 / stdm10.zip / SCRIPT.TXT < prev    next >
Text File  |  1992-11-28  |  8KB  |  355 lines

  1. //
  2. // Launch paintbrush.exe
  3. //
  4. :(pbrush.exe
  5. @Vv
  6. //
  7. //        SHOW SEVERAL INTRODUCTORY TEXT BOXES
  8. //
  9. :#L
  10. This small script will highlight several points of interest for you, as a demo
  11. script designer.
  12. I hope, you have already read README.TXT file, and you are familiar with the
  13. basic concepts of Stdemo Player. If not, you'll have a chance to do this later.
  14. .N
  15. As you can see, this box has two buttons. If you would like to stop this demo -
  16. select "Stop" button at any time, otherwise select "Continue". The same is correct
  17. for all dialog boxes to come.
  18. .N
  19. Try to move this dialog box, as you move any window. Note, however, that you can
  20. "drag" this box by selecting any point inside it, except buttons. It makes the whole
  21. business of moving a lot easier.
  22. #
  23. :#MU
  24. Even if you manage to move it outside the screen, so that it becomes impossible to
  25. move it back - you still are able to continue execution, by pressing C key, or to
  26. stop it by pressing S key.
  27. .S
  28. Note also how politely cursor points to the "Continue" button, so that the only
  29. things you have to do are: read and click.
  30. #
  31. :#M
  32. You may ask, how I created this solid background? Rather simple.
  33. I started the Paintbrush, and selected View Picture from it's menu.
  34. These are the commands, which have done this:
  35. .S
  36. :(pbrush.exe
  37. .N
  38. @Vv
  39. #
  40. //
  41. //        SHOW THE MAIN MENU
  42. //
  43. :LmainMenu
  44. :*L
  45. Now you may choose one of the topics and continue...
  46. 1startreadMe|Show the readme.txt.
  47. 2startScriptTxt|Show the script.txt ( currently running script).
  48. 4textBox|Demonstrate various TEXT  boxes.
  49. 5menuBox|Demonstrate various MENU  boxes.
  50. 6inputBox|Demonstrate various INPUT boxes.
  51. 7calcDemo|Demonstrate mouse actions.
  52. 9finishDemo|Finish this demo.
  53. *
  54. //
  55. //            SHOW README.TXT
  56. //
  57. :LstartreadMe
  58. :(notepad.exe readme.txt|1
  59. :LcontrolNotepad
  60. :*MDR
  61. 1pageDown|Scroll one page down
  62. 2pageUp|Scroll one page up
  63. 3goBottom|Show the last page
  64. 4goTop|Show the first page
  65. 5closeReadme|Return to the main menu
  66. *
  67. :LpageDown
  68. ]+
  69. :GcontrolNotepad
  70. :LpageUp
  71. ]-
  72. :GcontrolNotepad
  73. :LgoBottom
  74. %]E
  75. :GcontrolNotepad
  76. :LgoTop
  77. %]H
  78. :GcontrolNotepad
  79. :LcloseReadme
  80. :)
  81. :GmainMenu
  82. //
  83. //
  84. //             DEMONSTRATE VARIOUS TEXT BOXES
  85. //
  86. //
  87. :LtextBox
  88. :#W
  89. There are 5 text boxes available at the present time. They vary by their size
  90. only. Any can be placed at one of the 9 pre-defined screen locations.
  91. I'll show all of them one by one.
  92. .S
  93. This one - is the WIDE box.
  94. #
  95. :#NUL
  96. And this is the NARROW box. I programmed it to appear in the upper left corner
  97. of the screen.
  98. #
  99. :#SCD
  100. This one is SMALL. It is centered at the bottom of screen.
  101. #
  102. :#MRD
  103. This is the MEDIUM one.
  104. .S
  105. .S
  106. .S
  107. It is located in the bottom right corner.
  108. #
  109. :#L
  110. And finally the LARGE one.
  111. .N
  112. In the center.
  113. #
  114. :GmainMenu
  115. //
  116. //            SHOW README.TXT
  117. //
  118. :LstartScriptTxt
  119. :(notepad.exe script.txt|1
  120. :LcontrolScriptTxt
  121. :*MDR
  122. 1pageScriptDown|Scroll one page down
  123. 2pageScriptUp|Scroll one page up
  124. 3goScriptBottom|Show the last page
  125. 4goScriptTop|Show the first page
  126. 5closeScriptTxt|Return to the main menu
  127. *
  128. :LpageScriptDown
  129. ]+
  130. :GcontrolScriptTxt
  131. :LpageScriptUp
  132. ]-
  133. :GcontrolScriptTxt
  134. :LgoScriptBottom
  135. %]E
  136. :GcontrolScriptTxt
  137. :LgoScriptTop
  138. %]H
  139. :GcontrolScriptTxt
  140. :LcloseScriptTxt
  141. :)
  142. :GmainMenu
  143. //
  144. //
  145. //             DEMONSTRATE VARIOUS MENU BOXES
  146. //
  147. //
  148. :LmenuBox
  149. :#M
  150. You actually just saw the MENU box - you've chosen this topic from it.
  151. .S
  152. Now, I'll show several more menu boxes to demonstrate how you can customize
  153. them.
  154. #
  155. :*S
  156. Small box has only two items.
  157. 1cmenu|Whatever you chose -
  158. 2cmenu|I go ahead...
  159. *
  160. :Lcmenu
  161. :#S
  162. Then I'll show the same box, but without the header text.
  163. .S
  164. Note that the header field is hidden.
  165. #
  166. :*S
  167. 1cmenu1|The same box, but...
  168. 2cmenu1|without the header field.
  169. *
  170. :Lcmenu1
  171. :*M
  172. This is the MEDIUM menu box. All 5 fields are present, as you see.
  173. 1cmenu2|First menu item...
  174. 2cmenu2|Second menu item...
  175. 3cmenu2|Third menu item...
  176. 4cmenu2|Fourth menu item...
  177. 5cmenu2|Fifth menu item...
  178. *
  179. :Lcmenu2
  180. :*M
  181. Now look, this is the same box - but I skipped 1-st, 3-rd and 5-th items.
  182. 2cmenu3|Second menu item...
  183. 4cmenu3|Fourth menu item...
  184. *
  185. :Lcmenu3
  186. :*L
  187. And here the full-blown LARGE menu box goes... Of course, when you code it,
  188. you may skip the header and/or any of the items. Isn't it nice to have so many choices?
  189. 1cmenu4|This is the first item of the large menu box.
  190. 2cmenu4|This is the second item of the large menu box.
  191. 3cmenu4|This is the third item of the large menu box.
  192. 4cmenu4|This is the fourth item of the large menu box.
  193. 5cmenu4|This is the fifth item of the large menu box.
  194. 6cmenu4|This is the sixth item of the large menu box.
  195. 7cmenu4|This is the seventh item of the large menu box.
  196. 8cmenu4|This is the eighth item of the large menu box.
  197. 9cmenu4|This is the ninth item of the large menu box.
  198. *
  199. :Lcmenu4
  200. :GmainMenu
  201. :LinputBox
  202. //
  203. //
  204. //             DEMONSTRATE VARIOUS INPUT BOXES
  205. //
  206. //
  207. :#M
  208. There are 3 available sizes for the INPUT boxes: small, medium and large.
  209. Every box has a header text field and from 1 to 9 edit fields. For the medium and
  210. large boxes every edit field paired with the description field.
  211. .S
  212. You'd better look than read...
  213. #
  214. // Clear all variables.
  215. :$1
  216. :$2
  217. :$3
  218. :$4
  219. :$5
  220. :$6
  221. :$7
  222. :$8
  223. :$9
  224. :%S
  225. This is the small input box.
  226. Note, it has only one editable field.
  227. 1
  228. %
  229. :$1This is the text, assigned to $1
  230. :%S
  231. This is the same box, but it's edit field
  232. is not empty.
  233. 1
  234. %
  235. :$1
  236. :%M
  237. This is the MEDIUM input box. As you see it has 5 edit fields.
  238. Enter something...
  239. 1Description 1
  240. 2Description 2
  241. 3Description 3
  242. 4Description 4
  243. 5Description 5
  244. %
  245. :%M
  246. This is the same MEDIUM input box, but I skipped the 1-st and the 5-th fields.
  247. 2Description 2
  248. 3Description 3
  249. 4Description 4
  250. %
  251. :%L
  252. This is the full LARGE input box. Note that
  253. some fields are without description.
  254. 1Description for the field 1
  255. 2Description for the field 2
  256. 3Description for the field 3
  257. 4Description for the field 4
  258. 5
  259. 6Description for the field 6
  260. 7Description for the field 7
  261. 8
  262. 9Description for the field 9
  263. %
  264. :%L
  265. And this is the same LARGE input box. You may skip some fields in it. Note that
  266. some fields are missing.
  267. 1Description for the field 1
  268. 3Description for the field 3
  269. 5Description for the field 5
  270. 7Description for the field 7
  271. 9Description for the field 9
  272. %
  273. :#S
  274. And now I'll show how you can use what is entered into the edit
  275. fields of the INPUT box. I hope, you have typed something.
  276. #
  277. :(notepad.exe|1
  278. If you have entered some text into the edit fields,]!
  279. I'll type it here (values are enclosed in the angle brackets)]:]!
  280. The first field has the value]:        <$1>]!
  281. The second field has the value]:        <$2>]!
  282. The third field has the value]:        <$3>]!
  283. The fourth field has the value]:        <$4>]!
  284. The fifth field has the value]:        <$5>]!
  285. The sixth field has the value]:        <$6>]!
  286. The seventh field has the value]:    <$7>]!
  287. The eighth field has the value]:        <$8>]!
  288. The ninth field has the value]:        <$9>]!
  289. :#SDR
  290. Simply click continue...
  291. #
  292. :)
  293. // clear all variables
  294. :$1
  295. :$2
  296. :$3
  297. :$4
  298. :$5
  299. :$6
  300. :$7
  301. :$8
  302. :$9
  303. :GmainMenu
  304. //
  305. //            DEMONSTRATE MOUSE ACTIONS
  306. //
  307. :LcalcDemo
  308. :(calc.exe
  309. :C11
  310. :S324|283
  311. :OFC
  312. @VT
  313. // Clear
  314. :#SUL
  315. I'm going to move the cursor to the 'CLEAR' button - and click.
  316. #
  317. :M0|0
  318. :M38|66|100
  319. :BL1:BL0
  320. // click 2
  321. :#SUL
  322. Now I'm going to move the cursor to the '2' button - and click.
  323. #
  324. :M135|196|100
  325. :BL1:BL0
  326. // click *
  327. :#SUL
  328. Now I'll move to the '*' button - and click.
  329. #
  330. :M242|152|100
  331. :BL1:BL0
  332. // click 3
  333. :#SUL
  334. And here we go to the '3' button - and click.
  335. #
  336. :M189|196|100
  337. :BL1:BL0
  338. // click =
  339. :#SUL
  340. Now I'm going to click on '=' and, truly, I'm expecting to get....
  341. #
  342. :M295|240|100
  343. :BL1:BL0
  344. :#SUL
  345. Don't tell me that the result is not equal to six, please!
  346. #
  347. :C00
  348. :)
  349. :GmainMenu
  350. :LfinishDemo
  351. //
  352. // Kill paintbrush
  353. //
  354. :)
  355.